#ifndef LENSTRAYMODULESTATE_H
#define LENSTRAYMODULESTATE_H

#include "Tray/magtraystate.h"

class LensTrayModuleState : public MagTrayState
{
    Q_OBJECT

    Q_PROPERTY(bool lensTrayBufferHasTray READ lensTrayBufferHasTray WRITE setLensTrayBufferHasTray NOTIFY
                   lensTrayBufferHasTrayChanged)
    Q_PROPERTY(bool lensTrayLoaderHasTray READ lensTrayLoaderHasTray WRITE setLensTrayLoaderHasTray NOTIFY
                   lensTrayLoaderHasTrayChanged)

public:
    LensTrayModuleState(QObject *parent = nullptr) : MagTrayState(parent)
    {
        init();
    }

    bool lensTrayBufferHasTray() const
    {
        return m_lensTrayBufferHasTray;
    }

    bool lensTrayLoaderHasTray() const
    {
        return m_lensTrayLoaderHasTray;
    }

public slots:
    void setLensTrayBufferHasTray(bool lensTrayBufferHasTray)
    {
        if (m_lensTrayBufferHasTray == lensTrayBufferHasTray)
            return;

        m_lensTrayBufferHasTray = lensTrayBufferHasTray;
        emit lensTrayBufferHasTrayChanged(m_lensTrayBufferHasTray);
    }

    void setLensTrayLoaderHasTray(bool lensTrayLoaderHasTray)
    {
        if (m_lensTrayLoaderHasTray == lensTrayLoaderHasTray)
            return;

        m_lensTrayLoaderHasTray = lensTrayLoaderHasTray;
        emit lensTrayLoaderHasTrayChanged(m_lensTrayLoaderHasTray);
    }

signals:
    void lensTrayBufferHasTrayChanged(bool lensTrayBufferHasTray);

    void lensTrayLoaderHasTrayChanged(bool lensTrayLoaderHasTray);

private:
    bool m_lensTrayBufferHasTray = false;
    bool m_lensTrayLoaderHasTray = false;
};

#endif    // LENSTRAYMODULESTATE_H
